/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package JavaPractice;

/**
 *
 * @author Maestro
 */
public class DrawPyramid {

    public static final int LINES = 4;

    public static void main(String[] args){
        Squared();
    }
    
    public static void Squared(){
        for (int line = LINES; line >= 1; line--){
             for (int i = 1; i <= (line -1); i++){
                    System.out.print(" ");
             }
             int stars = (2 * LINES + 1) - 2 * line; //(formula) replaces the magic number 11
             for (int j =1; j <= stars; j++){
                    System.out.print('*');
        }
             System.out.println();
    }
}
}
